package com.itheima.store.dao;

import java.sql.SQLException;
import java.util.List;

import com.itheima.store.domain.PageBean;
import com.itheima.store.domain.User;
import com.itheima.store.domain.Book;

/**
 * 商品DAO的接口
 * @author admin
 *
 */
public interface BookDao {

	List<Book> findByHot()throws SQLException ;

	List<Book> findByNew()throws SQLException ;

	Integer findCountByBook_category_id(String book_category_id)throws SQLException ;

	List<Book> findPageByBook_category_id(String book_category_id, int begin, Integer pageSize)throws SQLException ;

	Book findByBook_id(String book_id)throws SQLException ;

	Integer findcountAll()throws SQLException ;

	List<Book> finByPage(int begin, Integer pageSize)throws SQLException ;

	void save(Book book)throws SQLException ;

	void update(Book book)throws SQLException ;
	
	void updateEdit(Book book)throws SQLException;

	List<Book> finPushDown(Integer isunder)throws SQLException ;

	Integer findAllByPage(String search)throws SQLException;
	
	List<Book> findAllByPage(int begin, int pageSize, String search)throws SQLException;

	void delete(String book_id)throws SQLException;

	Integer findCountByBookName(String book_name) throws SQLException;

	List<Book> findPageByBookName(String book_name, int begin, Integer pageSize) throws SQLException;
	
}
